Optimal. Leaf size=310 \[ \frac{b e m n \text{PolyLog}\left (2,-\frac{f x^2}{e}\right ) \left (a+b \log \left (c x^n\right )\right )}{2 f}-\frac{b^2 e m n^2 \text{PolyLog}\left (2,-\frac{f x^2}{e}\right )}{4 f}-\frac{b^2 e m n^2 \text{PolyLog}\left (3,-\frac{f x^2}{e}\right )}{4 f}-\frac{1}{2} b n x^2 \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^2\right )^m\right )+\frac{1}{2} x^2 \left (a+b \log \left (c x^n\right )\right )^2 \log \left (d \left (e+f x^2\right )^m\right )-\frac{b e m n \log \left (\frac{f x^2}{e}+1\right ) \left (a+b \log \left (c x^n\right )\right )}{2 f}+\frac{e m \log \left (\frac{f x^2}{e}+1\right ) \left (a+b \log \left (c x^n\right )\right )^2}{2 f}+b m n x^2 \left (a+b \log \left (c x^n\right )\right )-\frac{1}{2} m x^2 \left (a+b \log \left (c x^n\right )\right )^2+\frac{1}{4} b^2 n^2 x^2 \log \left (d \left (e+f x^2\right )^m\right )+\frac{b^2 e m n^2 \log \left (e+f x^2\right )}{4 f}-\frac{3}{4} b^2 m n^2 x^2 \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.536124, antiderivative size = 310, normalized size of antiderivative = 1., number of steps used = 17, number of rules used = 11, integrand size = 26, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.423, Rules used = {2305, 2304, 2378, 266, 43, 2351, 2337, 2391, 2353, 2374, 6589} \[ \frac{b e m n \text{PolyLog}\left (2,-\frac{f x^2}{e}\right ) \left (a+b \log \left (c x^n\right )\right )}{2 f}-\frac{b^2 e m n^2 \text{PolyLog}\left (2,-\frac{f x^2}{e}\right )}{4 f}-\frac{b^2 e m n^2 \text{PolyLog}\left (3,-\frac{f x^2}{e}\right )}{4 f}-\frac{1}{2} b n x^2 \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^2\right )^m\right )+\frac{1}{2} x^2 \left (a+b \log \left (c x^n\right )\right )^2 \log \left (d \left (e+f x^2\right )^m\right )-\frac{b e m n \log \left (\frac{f x^2}{e}+1\right ) \left (a+b \log \left (c x^n\right )\right )}{2 f}+\frac{e m \log \left (\frac{f x^2}{e}+1\right ) \left (a+b \log \left (c x^n\right )\right )^2}{2 f}+b m n x^2 \left (a+b \log \left (c x^n\right )\right )-\frac{1}{2} m x^2 \left (a+b \log \left (c x^n\right )\right )^2+\frac{1}{4} b^2 n^2 x^2 \log \left (d \left (e+f x^2\right )^m\right )+\frac{b^2 e m n^2 \log \left (e+f x^2\right )}{4 f}-\frac{3}{4} b^2 m n^2 x^2 \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 2305
Rule 2304
Rule 2378
Rule 266
Rule 43
Rule 2351
Rule 2337
Rule 2391
Rule 2353
Rule 2374
Rule 6589
Rubi steps
\begin{align*} \int x \left (a+b \log \left (c x^n\right )\right )^2 \log \left (d \left (e+f x^2\right )^m\right ) \, dx &=\frac{1}{4} b^2 n^2 x^2 \log \left (d \left (e+f x^2\right )^m\right )-\frac{1}{2} b n x^2 \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^2\right )^m\right )+\frac{1}{2} x^2 \left (a+b \log \left (c x^n\right )\right )^2 \log \left (d \left (e+f x^2\right )^m\right )-(2 f m) \int \left (\frac{b^2 n^2 x^3}{4 \left (e+f x^2\right )}-\frac{b n x^3 \left (a+b \log \left (c x^n\right )\right )}{2 \left (e+f x^2\right )}+\frac{x^3 \left (a+b \log \left (c x^n\right )\right )^2}{2 \left (e+f x^2\right )}\right ) \, dx\\ &=\frac{1}{4} b^2 n^2 x^2 \log \left (d \left (e+f x^2\right )^m\right )-\frac{1}{2} b n x^2 \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^2\right )^m\right )+\frac{1}{2} x^2 \left (a+b \log \left (c x^n\right )\right )^2 \log \left (d \left (e+f x^2\right )^m\right )-(f m) \int \frac{x^3 \left (a+b \log \left (c x^n\right )\right )^2}{e+f x^2} \, dx+(b f m n) \int \frac{x^3 \left (a+b \log \left (c x^n\right )\right )}{e+f x^2} \, dx-\frac{1}{2} \left (b^2 f m n^2\right ) \int \frac{x^3}{e+f x^2} \, dx\\ &=\frac{1}{4} b^2 n^2 x^2 \log \left (d \left (e+f x^2\right )^m\right )-\frac{1}{2} b n x^2 \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^2\right )^m\right )+\frac{1}{2} x^2 \left (a+b \log \left (c x^n\right )\right )^2 \log \left (d \left (e+f x^2\right )^m\right )-(f m) \int \left (\frac{x \left (a+b \log \left (c x^n\right )\right )^2}{f}-\frac{e x \left (a+b \log \left (c x^n\right )\right )^2}{f \left (e+f x^2\right )}\right ) \, dx+(b f m n) \int \left (\frac{x \left (a+b \log \left (c x^n\right )\right )}{f}-\frac{e x \left (a+b \log \left (c x^n\right )\right )}{f \left (e+f x^2\right )}\right ) \, dx-\frac{1}{4} \left (b^2 f m n^2\right ) \operatorname{Subst}\left (\int \frac{x}{e+f x} \, dx,x,x^2\right )\\ &=\frac{1}{4} b^2 n^2 x^2 \log \left (d \left (e+f x^2\right )^m\right )-\frac{1}{2} b n x^2 \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^2\right )^m\right )+\frac{1}{2} x^2 \left (a+b \log \left (c x^n\right )\right )^2 \log \left (d \left (e+f x^2\right )^m\right )-m \int x \left (a+b \log \left (c x^n\right )\right )^2 \, dx+(e m) \int \frac{x \left (a+b \log \left (c x^n\right )\right )^2}{e+f x^2} \, dx+(b m n) \int x \left (a+b \log \left (c x^n\right )\right ) \, dx-(b e m n) \int \frac{x \left (a+b \log \left (c x^n\right )\right )}{e+f x^2} \, dx-\frac{1}{4} \left (b^2 f m n^2\right ) \operatorname{Subst}\left (\int \left (\frac{1}{f}-\frac{e}{f (e+f x)}\right ) \, dx,x,x^2\right )\\ &=-\frac{1}{2} b^2 m n^2 x^2+\frac{1}{2} b m n x^2 \left (a+b \log \left (c x^n\right )\right )-\frac{1}{2} m x^2 \left (a+b \log \left (c x^n\right )\right )^2+\frac{b^2 e m n^2 \log \left (e+f x^2\right )}{4 f}+\frac{1}{4} b^2 n^2 x^2 \log \left (d \left (e+f x^2\right )^m\right )-\frac{1}{2} b n x^2 \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^2\right )^m\right )+\frac{1}{2} x^2 \left (a+b \log \left (c x^n\right )\right )^2 \log \left (d \left (e+f x^2\right )^m\right )-\frac{b e m n \left (a+b \log \left (c x^n\right )\right ) \log \left (1+\frac{f x^2}{e}\right )}{2 f}+\frac{e m \left (a+b \log \left (c x^n\right )\right )^2 \log \left (1+\frac{f x^2}{e}\right )}{2 f}+(b m n) \int x \left (a+b \log \left (c x^n\right )\right ) \, dx-\frac{(b e m n) \int \frac{\left (a+b \log \left (c x^n\right )\right ) \log \left (1+\frac{f x^2}{e}\right )}{x} \, dx}{f}+\frac{\left (b^2 e m n^2\right ) \int \frac{\log \left (1+\frac{f x^2}{e}\right )}{x} \, dx}{2 f}\\ &=-\frac{3}{4} b^2 m n^2 x^2+b m n x^2 \left (a+b \log \left (c x^n\right )\right )-\frac{1}{2} m x^2 \left (a+b \log \left (c x^n\right )\right )^2+\frac{b^2 e m n^2 \log \left (e+f x^2\right )}{4 f}+\frac{1}{4} b^2 n^2 x^2 \log \left (d \left (e+f x^2\right )^m\right )-\frac{1}{2} b n x^2 \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^2\right )^m\right )+\frac{1}{2} x^2 \left (a+b \log \left (c x^n\right )\right )^2 \log \left (d \left (e+f x^2\right )^m\right )-\frac{b e m n \left (a+b \log \left (c x^n\right )\right ) \log \left (1+\frac{f x^2}{e}\right )}{2 f}+\frac{e m \left (a+b \log \left (c x^n\right )\right )^2 \log \left (1+\frac{f x^2}{e}\right )}{2 f}-\frac{b^2 e m n^2 \text{Li}_2\left (-\frac{f x^2}{e}\right )}{4 f}+\frac{b e m n \left (a+b \log \left (c x^n\right )\right ) \text{Li}_2\left (-\frac{f x^2}{e}\right )}{2 f}-\frac{\left (b^2 e m n^2\right ) \int \frac{\text{Li}_2\left (-\frac{f x^2}{e}\right )}{x} \, dx}{2 f}\\ &=-\frac{3}{4} b^2 m n^2 x^2+b m n x^2 \left (a+b \log \left (c x^n\right )\right )-\frac{1}{2} m x^2 \left (a+b \log \left (c x^n\right )\right )^2+\frac{b^2 e m n^2 \log \left (e+f x^2\right )}{4 f}+\frac{1}{4} b^2 n^2 x^2 \log \left (d \left (e+f x^2\right )^m\right )-\frac{1}{2} b n x^2 \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^2\right )^m\right )+\frac{1}{2} x^2 \left (a+b \log \left (c x^n\right )\right )^2 \log \left (d \left (e+f x^2\right )^m\right )-\frac{b e m n \left (a+b \log \left (c x^n\right )\right ) \log \left (1+\frac{f x^2}{e}\right )}{2 f}+\frac{e m \left (a+b \log \left (c x^n\right )\right )^2 \log \left (1+\frac{f x^2}{e}\right )}{2 f}-\frac{b^2 e m n^2 \text{Li}_2\left (-\frac{f x^2}{e}\right )}{4 f}+\frac{b e m n \left (a+b \log \left (c x^n\right )\right ) \text{Li}_2\left (-\frac{f x^2}{e}\right )}{2 f}-\frac{b^2 e m n^2 \text{Li}_3\left (-\frac{f x^2}{e}\right )}{4 f}\\ \end{align*}
Mathematica [C] time = 0.251569, size = 814, normalized size = 2.63 \[ \frac{-2 f m x^2 a^2+2 e m \log \left (f x^2+e\right ) a^2+2 f x^2 \log \left (d \left (f x^2+e\right )^m\right ) a^2+4 b f m n x^2 a-4 b f m x^2 \log \left (c x^n\right ) a+4 b e m n \log (x) \log \left (1-\frac{i \sqrt{f} x}{\sqrt{e}}\right ) a+4 b e m n \log (x) \log \left (\frac{i \sqrt{f} x}{\sqrt{e}}+1\right ) a-2 b e m n \log \left (f x^2+e\right ) a-4 b e m n \log (x) \log \left (f x^2+e\right ) a+4 b e m \log \left (c x^n\right ) \log \left (f x^2+e\right ) a-2 b f n x^2 \log \left (d \left (f x^2+e\right )^m\right ) a+4 b f x^2 \log \left (c x^n\right ) \log \left (d \left (f x^2+e\right )^m\right ) a-3 b^2 f m n^2 x^2-2 b^2 f m x^2 \log ^2\left (c x^n\right )+4 b^2 f m n x^2 \log \left (c x^n\right )-2 b^2 e m n^2 \log ^2(x) \log \left (1-\frac{i \sqrt{f} x}{\sqrt{e}}\right )-2 b^2 e m n^2 \log (x) \log \left (1-\frac{i \sqrt{f} x}{\sqrt{e}}\right )+4 b^2 e m n \log (x) \log \left (c x^n\right ) \log \left (1-\frac{i \sqrt{f} x}{\sqrt{e}}\right )-2 b^2 e m n^2 \log ^2(x) \log \left (\frac{i \sqrt{f} x}{\sqrt{e}}+1\right )-2 b^2 e m n^2 \log (x) \log \left (\frac{i \sqrt{f} x}{\sqrt{e}}+1\right )+4 b^2 e m n \log (x) \log \left (c x^n\right ) \log \left (\frac{i \sqrt{f} x}{\sqrt{e}}+1\right )+b^2 e m n^2 \log \left (f x^2+e\right )+2 b^2 e m n^2 \log ^2(x) \log \left (f x^2+e\right )+2 b^2 e m \log ^2\left (c x^n\right ) \log \left (f x^2+e\right )+2 b^2 e m n^2 \log (x) \log \left (f x^2+e\right )-2 b^2 e m n \log \left (c x^n\right ) \log \left (f x^2+e\right )-4 b^2 e m n \log (x) \log \left (c x^n\right ) \log \left (f x^2+e\right )+b^2 f n^2 x^2 \log \left (d \left (f x^2+e\right )^m\right )+2 b^2 f x^2 \log ^2\left (c x^n\right ) \log \left (d \left (f x^2+e\right )^m\right )-2 b^2 f n x^2 \log \left (c x^n\right ) \log \left (d \left (f x^2+e\right )^m\right )+2 b e m n \left (2 a-b n+2 b \log \left (c x^n\right )\right ) \text{PolyLog}\left (2,-\frac{i \sqrt{f} x}{\sqrt{e}}\right )+2 b e m n \left (2 a-b n+2 b \log \left (c x^n\right )\right ) \text{PolyLog}\left (2,\frac{i \sqrt{f} x}{\sqrt{e}}\right )-4 b^2 e m n^2 \text{PolyLog}\left (3,-\frac{i \sqrt{f} x}{\sqrt{e}}\right )-4 b^2 e m n^2 \text{PolyLog}\left (3,\frac{i \sqrt{f} x}{\sqrt{e}}\right )}{4 f} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [F] time = 2.338, size = 0, normalized size = 0. \begin{align*} \int x \left ( a+b\ln \left ( c{x}^{n} \right ) \right ) ^{2}\ln \left ( d \left ( f{x}^{2}+e \right ) ^{m} \right ) \, dx \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F] time = 0., size = 0, normalized size = 0. \begin{align*} \frac{1}{4} \,{\left (2 \, b^{2} x^{2} \log \left (x^{n}\right )^{2} - 2 \,{\left (b^{2}{\left (n - 2 \, \log \left (c\right )\right )} - 2 \, a b\right )} x^{2} \log \left (x^{n}\right ) +{\left ({\left (n^{2} - 2 \, n \log \left (c\right ) + 2 \, \log \left (c\right )^{2}\right )} b^{2} - 2 \, a b{\left (n - 2 \, \log \left (c\right )\right )} + 2 \, a^{2}\right )} x^{2}\right )} \log \left ({\left (f x^{2} + e\right )}^{m}\right ) + \int -\frac{{\left (2 \,{\left (f m - f \log \left (d\right )\right )} a^{2} - 2 \,{\left (f m n - 2 \,{\left (f m - f \log \left (d\right )\right )} \log \left (c\right )\right )} a b +{\left (f m n^{2} - 2 \, f m n \log \left (c\right ) + 2 \,{\left (f m - f \log \left (d\right )\right )} \log \left (c\right )^{2}\right )} b^{2}\right )} x^{3} + 2 \,{\left ({\left (f m - f \log \left (d\right )\right )} b^{2} x^{3} - b^{2} e x \log \left (d\right )\right )} \log \left (x^{n}\right )^{2} - 2 \,{\left (b^{2} e \log \left (c\right )^{2} \log \left (d\right ) + 2 \, a b e \log \left (c\right ) \log \left (d\right ) + a^{2} e \log \left (d\right )\right )} x + 2 \,{\left ({\left (2 \,{\left (f m - f \log \left (d\right )\right )} a b -{\left (f m n - 2 \,{\left (f m - f \log \left (d\right )\right )} \log \left (c\right )\right )} b^{2}\right )} x^{3} - 2 \,{\left (b^{2} e \log \left (c\right ) \log \left (d\right ) + a b e \log \left (d\right )\right )} x\right )} \log \left (x^{n}\right )}{2 \,{\left (f x^{2} + e\right )}}\,{d x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F] time = 0., size = 0, normalized size = 0. \begin{align*}{\rm integral}\left ({\left (b^{2} x \log \left (c x^{n}\right )^{2} + 2 \, a b x \log \left (c x^{n}\right ) + a^{2} x\right )} \log \left ({\left (f x^{2} + e\right )}^{m} d\right ), x\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int{\left (b \log \left (c x^{n}\right ) + a\right )}^{2} x \log \left ({\left (f x^{2} + e\right )}^{m} d\right )\,{d x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]